﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using OdeToFood.Infrastructure;

namespace OdeToFood.Controllers
{
    [Log]
    public class CocinaController : Controller
    {
        //
        // GET: /Cocina/

        [HttpGet]
        public ActionResult Search(string name = "comodin")
        {
            //throw new Exception("oops!");

            //if (name == "comodin") {

                //return Json(new {cocinaName = name }, JsonRequestBehavior.AllowGet);
                //return File(Server.MapPath("~/Content/Site.css"), "text/css");
                //return RedirectToAction("Search", "Cocina", new { name = "french" } );

            //}
            
            name = Server.HtmlEncode(name);
            return Content(name);
        }

        

        public ActionResult Index()
        {
            return Content("Cocina/Index");
        }

    }
}
